home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 52 / Amiga Format AFCD52 (Issue 136, May 2000).iso / -serious- / programming / c / stormamiga_lib-v45_00d / include / ctype.h < prev    next >
C/C++ Source or Header  |  2000-02-28  |  1KB  |  64 lines

  1. #ifndef _INCLUDE_CTYPE_H
  2. #define _INCLUDE_CTYPE_H
  3.  
  4. /*
  5. **  $VER: ctype.h 1.2 (7.2.97)
  6. **  StormC Release 3.0
  7. **
  8. **  '(C) Copyright 1995/96/97 Haage & Partner Computer GmbH'
  9. **       All Rights Reserved
  10. */
  11.  
  12. #ifdef __cplusplus
  13. extern "C" {
  14. #endif
  15.  
  16. #ifndef _INLINE_INCLUDES
  17. int isalnum(int);
  18. int isalpha(int);
  19. int iscntrl(int);
  20. int isdigit(int);
  21. int isgraph(int);
  22. int islower(int);
  23. int isprint(int);
  24. int ispunct(int);
  25. int isspace(int);
  26. int isupper(int);
  27. int isxdigit(int);
  28. #endif
  29.  
  30. int tolower(int);
  31. int toupper(int);
  32. int which_xdigit(char);
  33.  
  34. #ifdef __cplusplus
  35. }
  36. #endif
  37.  
  38. #ifdef _INLINE_INCLUDES
  39. extern short int __ctypetable[];
  40. #define testbit(x) return __ctypetable[(short int) c] & x
  41. __inline int isalnum(int c) { testbit(0x0001); };
  42. __inline int isalpha(int c) { testbit(0x0002); };
  43. __inline int iscntrl(int c) { testbit(0x0004); };
  44. __inline int isdigit(int c) { testbit(0x0008); };
  45. __inline int isgraph(int c) { testbit(0x0010); };
  46. __inline int islower(int c) { testbit(0x0020); };
  47. __inline int isprint(int c) { testbit(0x0040); };
  48. __inline int ispunct(int c) { testbit(0x0080); };
  49. __inline int isspace(int c) { testbit(0x0100); };
  50. __inline int isupper(int c) { testbit(0x0200); };
  51. __inline int isxdigit(int c) { testbit(0x0400); };
  52. #undef testbit
  53. #endif
  54.  
  55. /*----- support for stormamiga.lib -----*/
  56.  
  57. #ifdef STORMAMIGA
  58.   #ifndef  CTYPE_STORMAMIGA_H
  59.     #include <ctype_stormamiga.h>
  60.   #endif
  61. #endif
  62.  
  63. #endif
  64.